package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.SysAlarmsMapper;
import com.ruoyi.system.domain.SysAlarms;
import com.ruoyi.system.service.ISysAlarmsService;

/**
 * alarmService业务层处理
 * 
 * @author ruoyi
 * @date 2022-05-11
 */
@Service
public class SysAlarmsServiceImpl implements ISysAlarmsService 
{
    @Autowired
    private SysAlarmsMapper sysAlarmsMapper;

    /**
     * 查询alarm
     * 
     * @param alarmId alarm主键
     * @return alarm
     */
    @Override
    public SysAlarms selectSysAlarmsByAlarmId(Long alarmId)
    {
        return sysAlarmsMapper.selectSysAlarmsByAlarmId(alarmId);
    }

    /**
     * 查询alarm列表
     * 
     * @param sysAlarms alarm
     * @return alarm
     */
    @Override
    public List<SysAlarms> selectSysAlarmsList(SysAlarms sysAlarms)
    {
        return sysAlarmsMapper.selectSysAlarmsList(sysAlarms);
    }

    /**
     * 新增alarm
     * 
     * @param sysAlarms alarm
     * @return 结果
     */
    @Override
    public int insertSysAlarms(SysAlarms sysAlarms)
    {
        return sysAlarmsMapper.insertSysAlarms(sysAlarms);
    }

    /**
     * 修改alarm
     * 
     * @param sysAlarms alarm
     * @return 结果
     */
    @Override
    public int updateSysAlarms(SysAlarms sysAlarms)
    {
        return sysAlarmsMapper.updateSysAlarms(sysAlarms);
    }

    /**
     * 批量删除alarm
     * 
     * @param alarmIds 需要删除的alarm主键
     * @return 结果
     */
    @Override
    public int deleteSysAlarmsByAlarmIds(Long[] alarmIds)
    {
        return sysAlarmsMapper.deleteSysAlarmsByAlarmIds(alarmIds);
    }

    /**
     * 删除alarm信息
     * 
     * @param alarmId alarm主键
     * @return 结果
     */
    @Override
    public int deleteSysAlarmsByAlarmId(Long alarmId)
    {
        return sysAlarmsMapper.deleteSysAlarmsByAlarmId(alarmId);
    }
}
